package com.shopping.mall.core.module.goodData.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.sql.Timestamp;
import java.util.Date;

@Data
public class GoodDataQueryVO {
    @ApiModelProperty(value = "主键")
    @TableId(type = IdType.UUID)
    private String id;

    @ApiModelProperty(value = "商品ID")
    private String goodId;

    @ApiModelProperty(value = "规格ID")
    private String specificationId;

    @ApiModelProperty(value = "商品名")
    private String goodName;

    @ApiModelProperty(value = "访问量")
    private Integer visitNum;

    @TableField(exist = false)
    @ApiModelProperty(value = "访问占比")
    private Double visitRate;

    @ApiModelProperty(value = "转化率")
    private Double convertRate;

    @ApiModelProperty(value = "已下单商品数量")
    private Integer orderGoodsNum;

    @ApiModelProperty(value = "已下单销售额")
    private Double orderSale;

    @ApiModelProperty(value = "日期")
    @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Timestamp date;

    @ApiModelProperty(value = "开始日期")
    @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date before;

    @ApiModelProperty(value = "结束日期")
    @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date after;

}
